package cn.xinfei.xdecision.data.core.vo;

import cn.xinfei.xdecision.common.model.datax.datamanage.v2.VariableCallLog;
import cn.xinfei.xdecision.data.core.frame.executors.IExecutorOutput;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Map;


@EqualsAndHashCode(callSuper = true)
@Data
public class GroovyExecutorResultEntity extends BaseExecutorEntity<GroovyExecutorResultEntity> implements IExecutorOutput {

    private Map<String, Object> groovyVarResult;
    private VariableCallLog variableCallLog;

    @Override
    public Map<String, Object> executorReuslt() {
        return groovyVarResult;
    }

    @Override
    public List<VariableCallLog> varCallLogList() {
        return Collections.singletonList(variableCallLog);
    }
}
